//querystring模块用于get参数相关操作

const querystring = require('querystring');

//querystring.stringify()构建get参数串
let str = querystring.stringify({
    name: '陈峰展',
    age: 28,
    like: [1, 3]
});
console.log(str);

//querystring.parse()解析、反序列化
console.log(querystring.parse(str));

//querystring.escape()转义
let str_ss = querystring.escape("哈哈哈");
console.log(str_ss);

//querystring.unescape()反转义
console.log(querystring.unescape(str_ss));
